<?php
abstract class Modal {

	const STATUS = "status";
	
	const STATUS_OK = "ok";
	const STATUS_ERROR = "error";
	const STATUS_BAD_REQUEST = "bad_request";
	const RESPONSE_PARAMETERS = "response_parameters";
    const PARAMETERS = "parameters";
	
	protected $__data;
	
	protected $status;

	protected function __construct(){
		$this->status = null;
	}

	public function set($key, $value) {
		$this->{$key} = $value;
	}

	public function __set($key, $value) {
		$this->__data[$key] = $value;
	}

	public function get($key) {
		return $this->{$key};
	}
	
	public function __get($key) {
		if (!isset($this->__data[$key])) return null;
		return $this->__data[$key];
	}

	public function getStatus() {
		return $this->status;
	}
}